<template>
  <div class="count-box">
     <h1>{{count}}</h1>
     <button @click="Cumulative">累加</button>
     <button @click="showThis" >查看当前的this</button>
  </div>
</template>

<script>
export default {
    name:'Count',
    //props传值过来直接字符串拿内容
    props:['a','b','c'],
    data(){
        return {
            count:0
        }
    },
    methods: {
        Cumulative(){
            this.count += 1
        },
        showThis(){
            console.log(this);
        }
    },
}
</script>

<style>
 .count-box{
    height: 200px;
    background-color: aqua;
 }
</style>